package com.songlanyun.modules.usercart.dao;

import com.songlanyun.modules.usercart.entity.UserCart;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.songlanyun.modules.usercart.model.vo.UserCartVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 会员的购物车表
 * 
 * @author lubo
 * @email sunlightcs@gmail.com
 * @date 2020-11-12 09:27:04
 */
@Mapper
public interface UserCartDao extends BaseMapper<UserCart> {

    List<UserCartVo> myCarts(@Param("userId") Long userId);

    int getCartGoodsCount(@Param("userId") Long userId, @Param("goodsId") Long goodsId);

}
